//package cn.flying.cloud.esb.core.camel.route;
//
//import javax.annotation.Resource;
//
//import org.apache.camel.LoggingLevel;
//import org.apache.camel.builder.RouteBuilder;
//import org.slf4j.Logger;
//import org.slf4j.LoggerFactory;
//import org.springframework.stereotype.Component;
//
//import cn.flying.cloud.esb.core.camel.process.ExceptionProcessor;
//import cn.flying.cloud.esb.core.camel.process.HttpMethodProcessor;
//import cn.flying.cloud.esb.core.camel.process.LoadbanacerForwardProcessor;
//import cn.flying.cloud.esb.core.camel.process.ParamValidProcessor;
//
///**
// * 接收请求转发到本地集群服务
// *
// * @author: admin
// * @date: 2025年04月12日 16:11
// * @version: 1.0
// */
//@Component
//public class LocalHttpRoute extends RouteBuilder {
//    private final Logger logger = LoggerFactory.getLogger(this.getClass());
//
//    @Resource
//    private ExceptionProcessor exceptionProcessor;
//    @Resource
//    private HttpMethodProcessor httpMethodProcessor;
//    @Resource
//    private ParamValidProcessor paramValidProcessor;
//    @Resource
//    private LoadbanacerForwardProcessor loadbanacerForwardProcessor;
//
//    @Override
//    public void configure() throws Exception {
//        // 全局异常处理器
//        onException(Exception.class)
//                .handled(true)
//                .process(exceptionProcessor);
//
//        // 定义接收
//        from("undertow:http://0.0.0.0:30000/api/fsmp")
//                .log(LoggingLevel.INFO, logger, "${body}")
//                .process(httpMethodProcessor)
//                .process(paramValidProcessor)
//                .process(loadbanacerForwardProcessor);
//    }
//}
